#define _CRT_SECURE_NO_WARNINGS 1
#include<iostream>
using namespace std;
class Date
{
public:
	void  operator+=(int x)
	{
		while (x--)
		{
			int months[13] = { 0,31,28,31,30,31,30,31,31,30,31,30,31 };
			_day += 1;
			if (_year % 4 == 0 && _year % 100 != 0 || _year % 400 == 0)
			{
				months[2] += 1;
			}
			if (_day > months[_month])
			{
				_month++;
				if (_month > 12)
				{
					_year++;
					_month = 1;
				}
				_day = 1;
			}
		}
	}
	void print()
	{
		cout << "year:" << _year << "->month:" << _month << "->_day:" << _day;
	}
private:
	int _year=2024;
	int _month=9;
	int _day=1;
};
int main()
{
	Date a;
	a +=9999;
	a.print();
}